#ifndef _NETWORK_H_
#define _NETWORK_H_

#include "gtmonitor.h"
#include "common.h"

typedef struct network_info
{
    char name[80];
    long long rx;
    long long tx;
} net_info;

extern int is_net_recording;

void init_network(void);

void net_dump(void);

void refresh_net(void);

void get_net_name_by_index(int index, char *buf);

long long get_net_rx_by_index(int index);

long long get_net_tx_by_index(int index);

int get_net_rxspeed_by_index(int index);

int get_net_txspeed_by_index(int index);

long long get_net_total_rx();

long long get_net_total_tx();

float get_net_total_rx_speed();

float get_net_total_tx_speed();

int get_net_nbr();

#endif /* _NETWORK_H_ */
